use check box to toggle content

50

/*
<input type="checkbox" name="mycheckbox" id="mycheckbox" value="0" />
<div id="toggle-content">
This content should appear when the checkbox is checked
</div>
*/


#toggle-content{
display:none;
}
#mycheckbox:checked ~ #toggle-content{
  display:block;
  height:100px;
}

Comments

Submit
0 Comments